package cc.cc4414.cc03.social.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import java.time.LocalDateTime;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 群组用户表
 * </p>
 *
 * @author cc
 * @since 2019-01-07
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("social_group_user")
public class GroupUser implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    private String id;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    /**
     * 用户id
     */
    private String userId;

    /**
     * 用户昵称。冗余字段
     */
    private String userNickname;

    /**
     * 群id
     */
    private String groupId;

    /**
     * 群名称。冗余字段
     */
    private String groupName;

    /**
     * 最后一条已读消息message_send表中的id
     */
    private String lastMessageSendId;


    public static final String ID = "id";

    public static final String CREATE_TIME = "create_time";

    public static final String USER_ID = "user_id";

    public static final String USER_NICKNAME = "user_nickname";

    public static final String GROUP_ID = "group_id";

    public static final String GROUP_NAME = "group_name";

    public static final String LAST_MESSAGE_SEND_ID = "last_message_send_id";

}
